﻿<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="Bandeja_Compras_Reporte_Excel.aspx.vb" Inherits="Cliente.Bandeja_Compras_Reporte_Excel" %>
<%@ PreviousPageType VirtualPath="~/Bandeja_Compras_Reporte.aspx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>Reporte de Compras x Dia</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
    
       <br/>
			<table width="500">
				<tr>
					<td>
						<table cellpadding="0" cellspacing="0">
							<tr align="left">
								<td colspan="1" valign="top" align="left"><img src="http://excelencia.no-ip.biz/SPE/App_Themes/Tema/red/pollo_amarillo.jpg" alt=""/></td>
							</tr>
						</table>
					</td>
					<td>&nbsp;</td>
					<td align="center" colspan="5" style="font-weight:bolder;text-transform:uppercase">REPORTE DE COMPRAS</td>
					<td>&nbsp;</td>
					<td align="right">Fecha:</td>
					<td align="left">&nbsp;<%=strFechaActual%></td>
				</tr>
				<tr>
				<td colspan="8">&nbsp;</td>
				<td align="right">Hora:</td>
				<td align="left">&nbsp;<%=strHoraActual%></td>
				</tr>
				
			</table>
			<br />
			<br />
			<%If ParamLocal <> "" Or ParamFecha <> "" Or ParamGrupo <> "" Then%>
			<table style="background-color:Gray; color:white">
			<%If ParamLocal <> "" Then%>
			<tr>
			<td style="font-weight:bolder">
			Local:
			</td>
			<td colspan="2">
			&nbsp;<%=ParamNomLocal%>
			</td>
			</tr>
			<%end if%>
			<%If ParamFecha <> "" Then%>
			<tr>
			<td style="font-weight:bolder">
			Fecha:
			</td>
			<td colspan="2">
			&nbsp;<%=ParamFecha%>
			</td>
			</tr>
			<%end if%>
			<%If ParamGrupo <> "" Then%>
			<tr>
			<td style="font-weight:bolder">
			Grupo:
			</td>
			<td colspan="2">
			&nbsp;<%=ParamNomGrupo%>
			</td>
			</tr>
			<%end if%>
			</table>
			<br />
			<br />
			<%end if %>
			
			<table id="Table22" width="760" border="1">
				<tr style="background-color:#FFC827" align="left" valign="middle" >
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Compra</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Proveedor</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Documento</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Número</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Ctd</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Und</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Producto</td>
					<td align="center" style="font-weight:bolder;text-transform:uppercase">Total</td>
																	
					
				</tr>
			</table>
			<%dim i as long
				  i = 0
				%>
			
			<table id="Table1" width="760" border="1">
				<tr align="left">
					<%
					    While i < dsConsulta.Tables(0).Rows.Count%>
					    
					<td align="left">&nbsp;<%=dsConsulta.Tables(0).Rows(i)("Compra")%></td>
					<td align="left">&nbsp;<%=dsConsulta.Tables(0).Rows(i)("Nombre")%></td>
					<td align="left">&nbsp;<%=Trim(dsConsulta.Tables(0).Rows(i)("Documento"))%></td>
					<td align="right"><%=Trim(dsConsulta.Tables(0).Rows(i)("Numero"))%></td>
					<td align="right"><%=dsConsulta.Tables(0).Rows(i)("Cantidad")%></td>
					<td align="left"><%=dsConsulta.Tables(0).Rows(i)("NomUnidad")%></td>
					<td align="left"><%=dsConsulta.Tables(0).Rows(i)("NomInsumo")%></td>
					<td align="right"><%=dsConsulta.Tables(0).Rows(i)("Total")%></td>
											
							
				</tr>
				
				<%		i = i + 1						
						end while%>
			</table>
    
    </div>
    </form>
</body>
</html>
